package com.iweb.controller;

import com.iweb.commons.ResultEntity;
import com.iweb.model.Tag;
import com.iweb.service.TagService;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import javax.annotation.Resource;
import java.util.List;

/**
 * Time :2022/8/15 14:03
 * Author : kriller
 * Project : steam-malls
 */
@RestController
@RequestMapping("tag")
public class TagController {

    @Resource
    private TagService tagService;

    @GetMapping("list")
    public ResultEntity<List<Tag>> listTag(){
        List<Tag> tags = tagService.listTag();
        return new ResultEntity<>(2000,"获取标签列表",true,tags);
    }


}
